﻿using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Text;

namespace FySystem.Data.OrmA.Resolvers.Lambdas
{
    class DbSelectExpression<T>
    {
        internal DbKeywords DbKeywords { get; set; }

        internal Expression<Func<T, object>> ExpSelect { get; set; }

        internal Expression<Func<T,bool>> ExpOper { get; set; }

        internal object[] Parameters { get; set; }

        internal DbSelectExpression(DbKeywords dbKeywords) 
        {
            DbKeywords = dbKeywords;
        }

        internal DbSelectExpression(DbKeywords dbKeywords, Expression<Func<T, object>> expression, params object[] parameters)
        {
            DbKeywords = dbKeywords;
            ExpSelect = expression;
            Parameters = parameters;
        }

        internal DbSelectExpression(DbKeywords dbKeywords, Expression<Func<T,bool>> expression,params object[] parameters)
        {
            DbKeywords = dbKeywords;
            ExpOper = expression;
            Parameters = parameters;
        }
    }
}
